package com.sheng.whyclass.person.model;

import com.google.gson.Gson;
import com.google.gson.JsonSyntaxException;
import com.google.gson.annotations.SerializedName;

import java.util.List;

/**
 * Created by Administrator on 2016/4/4.
 */
public class StudentIdInfoResp extends BaseResult{


    /**
     * static : 1
     * data : [{"id":"1","topic":"第二十章","content":"1、AJAX 包含哪些技术？ ","issue_time":"2016-03-28 21:55:23","s_id":"1","w_c_id":"34","answer_content":" 我不知道","is_finished":"1","is_checked":"0","name":"xiaoming","pass":"123456","class":"1","department":"ceshi"},{"id":"1","topic":"第十九章","content":"1、如何在母版页中使用 ASP.NET AJAX? ","issue_time":"2016-03-28 21:54:53","s_id":"1","w_c_id":"33","answer_content":" 你猜","is_finished":"1","is_checked":"0","name":"xiaoming","pass":"123456","class":"1","department":"ceshi"},{"id":"1","topic":"第十章","content":"1举例说明 Panel 、 MultiView 、 Wizard 控件的作用 ","issue_time":"2016-03-28 21:50:46","s_id":"1","w_c_id":"24","answer_content":" 测试","is_finished":"1","is_checked":"0","name":"xiaoming","pass":"123456","class":"1","department":"ceshi"},{"id":"1","topic":"第一章","content":"1.一个学校有多 个分院 ，每个分院有各自的 网站 ，如果提供一台 WEB 服务器，如何设 置？ 2.在访问一些网 站时， 为什么只需要输入域 名就 能访问网站主页？","issue_time":"2016-03-28 21:45:53","s_id":"1","w_c_id":"15","answer_content":"diyizhang","is_finished":"1","is_checked":"0","name":"xiaoming","pass":"123456","class":"1","department":"ceshi"},{"id":"1","topic":"第五章","content":"1.说明修饰符 public 、 internal 、 protected 、 protected internal 、 private 的区别？ ","issue_time":"2016-03-28 21:48:35","s_id":"1","w_c_id":"19","answer_content":"55555","is_finished":"1","is_checked":"0","name":"xiaoming","pass":"123456","class":"1","department":"ceshi"},{"id":"1","topic":"第六章","content":"1.值类型和引用 类型有 什么区别？ ","issue_time":"2016-03-28 21:48:58","s_id":"1","w_c_id":"20","answer_content":"666","is_finished":"1","is_checked":"0","name":"xiaoming","pass":"123456","class":"1","department":"ceshi"},{"id":"1","topic":"第八章","content":"1） 说明 Image 、 ImageButton 、 ImageMap 控件的区别 ","issue_time":"2016-03-28 21:49:49","s_id":"1","w_c_id":"22","answer_content":"888","is_finished":"1","is_checked":"0","name":"xiaoming","pass":"123456","class":"1","department":"ceshi"},{"id":"1","topic":"第二章","content":"1.文件系统、本 地 IIS 、 FTP 站点和远程站点的 区别是什么？ 2.说明什么是虚 拟主机 ， Internet 上提的虚拟主 机是如何运行的？","issue_time":"2016-03-28 21:46:20","s_id":"1","w_c_id":"16","answer_content":"22223","is_finished":"1","is_checked":"0","name":"xiaoming","pass":"123456","class":"1","department":"ceshi"},{"id":"2","topic":"第一章","content":"1.一个学校有多 个分院 ，每个分院有各自的 网站 ，如果提供一台 WEB 服务器，如何设 置？ 2.在访问一些网 站时， 为什么只需要输入域 名就 能访问网站主页？","issue_time":"2016-03-28 21:45:53","s_id":"2","w_c_id":"15","answer_content":"aaaa","is_finished":"1","is_checked":"0","name":"xiaoming2","pass":"123","class":"123","department":"123"}]
     */

    @SerializedName("static")
    private int staticX;
    /**
     * id : 1
     * topic : 第二十章
     * content : 1、AJAX 包含哪些技术？
     * issue_time : 2016-03-28 21:55:23
     * s_id : 1
     * w_c_id : 34
     * answer_content :  我不知道
     * is_finished : 1
     * is_checked : 0
     * name : xiaoming
     * pass : 123456
     * class : 1
     * department : ceshi
     */

    private List<DataBean> data;

    public static StudentIdInfoResp getFromJson(String json) {
            if (json == null) {
                return null;
            }
            Gson gson = new Gson();
            StudentIdInfoResp info = null;
            try {
                info = gson.fromJson(json, StudentIdInfoResp.class);
            } catch (JsonSyntaxException jsonSyntaxException) {
            }
            return info;
        }

        public static String toJsonString(StudentIdInfoResp data) {
            if (data == null) {
                return null;
            }
            String js = null;
            Gson gson = new Gson();
            try {
                js = gson.toJson(data);
            } catch (JsonSyntaxException jsonSyntaxException) {
            }

            return js;
        }

    public int getStaticX() {
        return staticX;
    }

    public void setStaticX(int staticX) {
        this.staticX = staticX;
    }

    public List<DataBean> getData() {
        return data;
    }

    public void setData(List<DataBean> data) {
        this.data = data;
    }


    public static class DataBean {

        private String s_id;


        public String getS_id() {
            return s_id;
        }

        public void setS_id(String s_id) {
            this.s_id = s_id;
        }


    }
}
